<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<script src="js/echarts.js" type="text/javascript" charset="utf-8"></script>

		<link rel="stylesheet" type="text/css" href="js/bootstarp-3.3.7/css/bootstrap.min.css" />
		<script src="js/jquery/jquery-3.2.1.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/bootstarp-3.3.7/js/bootstrap.min.js" type="text/javascript" charset="utf-8"></script>
		<link rel="stylesheet" type="text/css" href="js/bootstarp-table-1.11.1/bootstrap-table.min.css" />
		<script src="js/bootstarp-table-1.11.1/bootstrap-table.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/bootstarp-table-1.11.1/bootstrap-table-zh-CN.min.js" type="text/javascript" charset="utf-8"></script>

		<link rel="stylesheet" type="text/css" href="assets/layui-v2.4.5/layui/css/layui.css" />
		<script src="assets/layui-v2.4.5/layui/layui.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/bootstrap-table-export.js"></script>
		<script src="js/tableExport.min.js"></script>
		<script src="js/xlsx.core.min.js"></script>
		<script src="js/FileSaver.min.js"></script>


		<script>
			$(function() { //, headers: { 'x-requested-with': 'XMLHttpRequest' }]
	
				$.ajaxSetup({
					crossDomain: true,
					xhrFields: {
						withCredentials: true
					}
				});
			});
		</script>
	</head>

	<body>
		<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
			<ul class="layui-tab-title">
				<li class="layui-this">门诊费用统计</li>
				<li>门诊处方统计</li>
				<li>挂号费统计</li>
				<li>收费员统计</li>
			</ul>
			<div class="layui-tab-content" style="height: 100px;">
				<div class="layui-tab-item layui-show">
				<table>
					<tr>
										<td width="20">
										</td>
										<td>
											日期&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="Workrqone" value="" />
										</td>
										<td>
											&nbsp;&nbsp;-&nbsp;&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="Workrqtwo" value="" />
										</td>
										<td>
											&nbsp;&nbsp;
										</td>
										<td>
											&nbsp;&nbsp;医生姓名&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="text" id="Worktext" value="" />
										</td>
										
										<td>
											&nbsp;&nbsp;<input style="width: 80px;" class="btn btn-primary" type="button" id="selone" name="" value="查询" />
										</td>
										<td align="right" width="700">

										</td>
									</tr>
								</table>
				<table id="worktable"></table>
				</div>
				<div class="layui-tab-item">
					<table>
									<tr>
										<td width="20">

										</td>
										<td>
											日期&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="MzcfTjrqone" value="" />
										</td>
										<td>
											&nbsp;&nbsp;-&nbsp;&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="MzcfTjrqtwo" value="" />
										</td>
										<td>
											&nbsp;&nbsp;
										</td>
										<td>
											&nbsp;&nbsp;医生姓名&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="text" id="MzcfTjtext" value="" />
										</td>
										
										<td>
											&nbsp;&nbsp;<input style="width: 80px;" class="btn btn-primary" type="button" id="seltwo" name="" value="查询" />
										</td>
										<td align="right" width="700">
											<!--<button style="width: 80px;" type="button" id="exportBtn" style="margin-left:50px" id="export-excel btn_download" class="btn btn-primary" data-table="#tab">导出</button>-->
										</td>
									</tr>
								</table>
					<table id="wortable"></table>
				</div>
				<div class="layui-tab-item">
					<table>
						<tr>
										<td width="20">
										</td>
										<td>
										日期&nbsp;&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="GhfTjrqone" value="" />
										</td>
										<td>
											&nbsp;&nbsp;-&nbsp;&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="GhfTjrqtwo" value="" />
										</td>
										<td>
											&nbsp;&nbsp;
										</td>
										<td>
											&nbsp;&nbsp;医生姓名&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="text" id="GhfTjtext" value="" />
										</td>
										
										<td>
											&nbsp;&nbsp;<input style="width: 80px;" class="btn btn-primary" type="button" id="selshui" name="" value="查询" />
										</td>
										<td align="right" width="700">
											<!--<button style="width: 80px;" type="button" id="exportBtn" style="margin-left:50px" id="export-excel btn_download" class="btn btn-primary" data-table="#tab">导出</button>-->
										</td>
									</tr>
								</table>
					<table id="wotable"></table>
				</div>
				<div class="layui-tab-item">
					<table>
									<tr>
										<td width="20">

										</td>
										<td>
											日期&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="SfyTjrqone" value="" />
										</td>
										<td>
											&nbsp;&nbsp;-&nbsp;&nbsp;
										</td>
										<td>
											<input class="form-control" type="date" id="SfyTjrqtwo" value="" />
										</td>
										<td>
											&nbsp;&nbsp;
										</td>
										<td>
											&nbsp;&nbsp;医生姓名&nbsp;:&nbsp;
										</td>
										<td>
											<input class="form-control" type="text" id="SfyTjtext" value="" />
										</td>
										
										<td>
											&nbsp;&nbsp;<input style="width: 80px;" class="btn btn-primary" type="button" id="selfour" name="" value="查询" />
										</td>
										<td align="right" width="700">
											<!--<button style="width: 80px;" type="button" id="exportBtn" style="margin-left:50px" id="export-excel btn_download" class="btn btn-primary" data-table="#tab">导出</button>-->
										</td>
									</tr>
								</table>
					<table id="wtable"></table>
				</div>
			</div>
		</div>

	</body>

</html>
<script type="text/javascript">
	layui.use('element', function() {
		var $ = layui.jquery,
			element = layui.element; //Tab的切换功能，切换事件监听等，需要依赖element模块

	})

	$(function() {
		$('#worktable').bootstrapTable({
			url: "http://localhost:8090/FindMZFY",
			queryParams:'querywork',
			columns: [{
				field: 'oname',
				title: '医生',
				align: 'center'
			}, {
				field: 'mzsl',
				title: '门诊数量',
				align: 'center'
			}, {
				field: 'jzss',
				title: '就诊实收',
				align: 'center'
			}, {
				field: 'ghss',
				title: '挂号实收',
				align: 'center'
			}, {
				field: 'jztf',
				title: '就诊退费',
				align: 'center',
				formatter: function(value, row, index) {
					if (row.jztf==null||row.jztf=='') {
						return '0';
					} else{
						return row.jztf;
					}
				}
			}, {
				field: 'ghtf',
				title: '挂号退费',
				align: 'center',
				formatter: function(value, row, index) {
					if (row.ghtf==null||row.ghtf=='') {
						return '0';
					} else{
						return row.ghtf;
					}
				}
			}],
			showExport: true,   
			      exportDataType: "basic",             
			      exportTypes:['excel','xlsx'],	  
//			      exportButton: $('#daochu'),
			      exportOptions:{  
			          fileName: '数据导出',             
			          worksheetName: 'Sheet1',         
			          tableName: '商品数据表',  
			          excelstyles: ['background-color', 'color', 'font-size', 'font-weight'],  
			      }
		})
		
		$("#selone").click(function(){
			$("#worktable").bootstrapTable("refresh");
			
			
		})
		
		
		
	})
	
	 function querywork(){
		return{
			'rqone':$("#Workrqone").val(),
			'rqtwo':$("#Workrqtwo").val(),
			'name':$("#Worktext").val()
			
			
		}
		
	}
	
	
	

	$(function() {
		$('#wortable').bootstrapTable({
			url: "http://localhost:8090/FindCFTJ",
			queryParams:'queryMzcfTj',
			columns: [{
				field: 'oname',
				title: '医生',
				align: 'center'
			}, {
				field: 'cfsl',
				title: '处方数量',
				align: 'center'
			}, {
				field: 'zycf',
				title: '中药处方',
				align: 'center',
				formatter: function(value, row, index) {
					if (row.zycf==null||row.zycf=='') {
						return '0';
					} else{
						return row.zycf;
					}
				}
			}, {
				field: 'fjfy',
				title: '附加费用',
				align: 'center'
			}, {
				field: 'jcxm',
				title: '检查项目',
				align: 'center'
			}, {
				field: 'tfjg',
				title: '退费金额',
				align: 'center',
				formatter: function(value, row, index) {
					if (row.tfjg==null||row.tfjg=='') {
						return '0';
					} else{
						return row.tfjg;
					}
				}
			}, {
				field: 'ssjg',
				title: '实收金额',
				align: 'center'
			}]
			,showExport: true,   
			      exportDataType: "basic",             
			      exportTypes:['excel','xlsx'],	  
//			      exportButton: $('#daochu'),
			      exportOptions:{  
			          fileName: '数据导出',             
			          worksheetName: 'Sheet1',         
			          tableName: '商品数据表',  
			          excelstyles: ['background-color', 'color', 'font-size', 'font-weight'],  
			      }
		})
		
		$("#seltwo").click(function(){
			$("#wortable").bootstrapTable("refresh");
			
			 
		})
		
		
	})
	
	 function queryMzcfTj(){
		return{
			'rqone':$("#MzcfTjrqone").val(),
			'rqtwo':$("#MzcfTjrqtwo").val(),
			'name':$("#MzcfTjtext").val()
			
			
		}
		
	}
	
	

	$(function() {
		$('#wotable').bootstrapTable({
			url: "http://localhost:8090/FindGHF",
			queryParams:'queryGhfTj',
			columns: [{
				field: 'oname',
				title: '医生',
				align: 'center'
			}, {
				field: 'ghmc',
				title: '挂号名称',
				align: 'center'
			}, {
				field: 'zfyzje',
				title: '子费用总金额',
				align: 'center'
			}, {
				field: 'zfysl',
				title: '子费用数量',
				align: 'center'
			}, {
				field: 'ghzje',
				title: '挂号总金额',
				align: 'center'
			}],
			showExport: true,   
			      exportDataType: "basic",             
			      exportTypes:['excel','xlsx'],	  
//			      exportButton: $('#daochu'),
			      exportOptions:{  
			          fileName: '数据导出',             
			          worksheetName: 'Sheet1',         
			          tableName: '商品数据表',  
			          excelstyles: ['background-color', 'color', 'font-size', 'font-weight'],  
			      }
		})
		$("#selshui").click(function(){
			$("#wotable").bootstrapTable("refresh");
			
			 
		})
		
		
	})
	
	function queryGhfTj(){
		return{
			'rqone':$("#GhfTjrqone").val(),
			'rqtwo':$("#GhfTjrqtwo").val(),
			'name':$("#GhfTjtext").val()
			
			
		}
		
	}
	
	

	$(function() {
		$('#wtable').bootstrapTable({
			url: "http://localhost:8090/FindSFY",
			queryParams:'querySfyTj',
			columns: [{
				field: 'oname',
				title: '收费员',
				align: 'center'
			}, {
				field: 'sfcs',
				title: '收费次数',
				align: 'center'
			}, {
				field: 'ssje',
				title: '实收金额',
				align: 'center'
			}, {
				field: 'xjzf',
				title: '现金支付',
				align: 'center'
			}, {
				field: 'wxzf',
				title: '微信支付',
				align: 'center'
			}, {
				field: 'zfbzf',
				title: '支付宝支付',
				align: 'center'
			}],
			showExport: true,   
			      exportDataType: "basic",             
			      exportTypes:['excel','xlsx'],	  
//			      exportButton: $('#daochu'),
			      exportOptions:{  
			          fileName: '数据导出',             
			          worksheetName: 'Sheet1',         
			          tableName: '商品数据表',  
			          excelstyles: ['background-color', 'color', 'font-size', 'font-weight'],  
			      }
		})
		
		$("#selfour").click(function(){
			$("#wtable").bootstrapTable("refresh");
			
			
		})
	})
	
	
	function querySfyTj(){
		return{
			'rqone':$("#SfyTjrqone").val(),
			'rqtwo':$("#SfyTjrqtwo").val(),
			'name':$("#SfyTjtext").val()
			
			
		}
		
	}
</script>